package collectionFramework;

import java.util.Stack;

public class MyStack {
	public static void main(String[] args) {
		Stack<Integer> s = new Stack<Integer>();
		s.push(100);
		s.push(200);
		s.push(300);
		s.push(400);
		System.out.println("Stack: " + s);
		System.out.println(s.pop());
		System.out.println("Stack(after pop): " + s);
		System.out.println(s.peek());
		System.out.println("Stack(after peek): " + s);
		System.out.println("Pos of 100 in stack: " + s.search(300));
	}
}
